#ifndef PINGINTERFACE_H
#define PINGINTERFACE_H

#include <QObject>

class QUrl;

class PingInterface : public QObject
{
    Q_OBJECT

public:
    explicit PingInterface( QObject *parent = NULL ) :
        QObject( parent )
    {}

    /**
     * @brief Send a ping request. The result will be send by
     *        the signal "pingResult()".
     * @param url A QUrl object.
     */
    virtual void send( const QUrl &url ) = 0;
    
signals:
    /**
     * @brief Signal send if host unavailable.
     */
    void hostUnavailable();

    /**
     * @brief Result of a ping.
     * @param int The result in milliseconds (ms).
     */
    void pingResult( int );
    
public slots:
    
};

#endif // PINGINTERFACE_H
